package com.atguigu.gulimall.product.service;

import com.atguigu.gulimall.product.vo.AttrGroupRelationVo;
import com.atguigu.gulimall.product.vo.AttrRespVo;
import com.atguigu.gulimall.product.vo.AttrVo;
import com.baomidou.mybatisplus.extension.service.IService;
import com.atguigu.common.utils.PageUtils;
import com.atguigu.gulimall.product.entity.AttrEntity;

import java.util.List;
import java.util.Map;

/**
 * 商品属性
 *
 * @author lemon
 * @email 2313812755@qq.com
 * @date 2022-11-19 23:00:39
 */
public interface AttrService extends IService<AttrEntity> {

    PageUtils queryPage(Map<String, Object> params);


    void saveAttr(AttrVo attr);

//    分页查询我们的规格参数列表
    PageUtils queryBaseAttrPage(Map<String, Object> params, Long catelogId, String attrType);

    // 额外获取三级分类的路径
    AttrRespVo getAttrInfo(Long attrId);

    // 修改方法也要进行多张表的修改
    void updateAttr(AttrVo attrVo);


    List<AttrEntity> getattrRelation(Long attrgroupId);


    void attrRelationDelete(AttrGroupRelationVo[] ovs);

    PageUtils getNoRelation(Long attrgroupId, Map<String, Object> params);

    List<Long> selectSearchAttrs(List<Long> attrIds);

}

